<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
use Illuminate\Support\Facades\DB;

class THisdataCo2concentration extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('t_hisdata_CO2Concentration', function (Blueprint $table) {
             $table->engine = 'MyISAM';
             $table->charset = 'utf8';
             $table->collation = 'utf8_general_ci';
            // CONTENT
            $table->bigIncrements('hd_index')->nullable(false)->comment('');
			$table->datetime('rd_updatetime')->nullable(false)->comment('');
			$table->datetime('hd_datetime')->nullable(false)->comment('');
			$table->unsignedBigInteger('pdi_index')->nullable(false)->default(0)->comment('');
			$table->float('hd_Concentration1', 9, 2)->nullable()->default(0)->comment('');
			$table->float('hd_Concentration2', 9, 2)->nullable()->default(0)->comment('');
			$table->float('hd_Concentration3', 9, 2)->nullable()->default(0)->comment('');
			$table->float('hd_Concentration4', 9, 2)->nullable()->default(0)->comment('');
			$table->float('hd_Concentration5', 9, 2)->nullable()->default(0)->comment('');
			$table->float('hd_Concentration6', 9, 2)->nullable()->default(0)->comment('');
			$table->float('hd_Concentration7', 9, 2)->nullable()->default(0)->comment('');
			$table->float('hd_Concentration8', 9, 2)->nullable()->default(0)->comment('');
			$table->float('hd_Concentration9', 9, 2)->nullable()->default(0)->comment('');
			$table->float('hd_Concentration10', 9, 2)->nullable()->default(0)->comment('');
			$table->float('hd_Concentration_num', 9, 2)->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration1hwarn')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration2hwarn')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration3hwarn')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration4hwarn')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration5hwarn')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration6hwarn')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration7hwarn')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration8hwarn')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration9hwarn')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration10hwarn')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration1lwarn')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration2lwarn')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration3lwarn')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration4lwarn')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration5lwarn')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration6lwarn')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration7lwarn')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration8lwarn')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration9lwarn')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration10lwarn')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration1consta')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration2consta')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration3consta')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration4consta')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration5consta')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration6consta')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration7consta')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration8consta')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration9consta')->nullable()->default(0)->comment('');
			$table->boolean('hd_Concentration10consta')->nullable()->default(0)->comment('');
			$table->boolean('hd_NetCom')->nullable()->default(0)->comment('');
			$table->unique('hd_index', 'hd_index');
			
        });

        
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('t_hisdata_CO2Concentration');
    }
}
